home *** CD-ROM | disk | FTP | other *** search
/ Aminet 23 / Aminet 23 (1998)(GTI - Schatztruhe)[!][Feb 1998].iso / Aminet / text / edit / Smartindent.lha / Smartindent / Source / smakefile < prev    next >
Makefile  |  1997-12-14  |  3KB  |  71 lines

  1. OBJ= StartUp.o LibInit.o LibFuncs.o dispatcher.o util.o semantics_c.o semantics_lisp.o
  2. NAME= smartindent.api
  3.  
  4. $(NAME):  $(OBJ)
  5.     slink $(OBJ) LIB lib:sc.lib lib:amiga.lib NODEBUG to $(NAME)
  6.     -delete $(NAME).info
  7.  
  8. dist:
  9.     ed smartindent.h
  10.     ed smartindent.readme sticky
  11.     -delete LibInit.o
  12.     -delete ram:makelha all
  13.     makedir ram:makelha
  14.     copy icons/\#? ram:makelha/ all
  15.     copy presets/\#? ram:makelha/Smartindent/presets/ all
  16.     copy \#?.[ch] test_input.\#? test_correct.\#? SCOPTIONS smakefile ram:makelha/Smartindent/Source/
  17.     addicon ram:makelha/Smartindent/Source/\#?
  18.     copy golded:tools/regedit/regedit ram:makelha/Smartindent/bin/
  19.     copy Smartindent.readme Install Install_d.bat Install_e.bat COPYING ram:makelha/Smartindent/
  20.     smake
  21.     copy smartindent.api ram:makelha/Smartindent/api/smartindent.api
  22.     -delete smartindent.lha
  23.     lha a smartindent.lha ram:makelha/
  24.  
  25. clean:
  26.     -delete \#?.o \#?.info $(NAME)
  27.  
  28. ci:
  29.     ci -l Install\#? \#?.c \#?.h SCOPTIONS smakefile Smartindent.readme
  30.  
  31. test:
  32.     @smake m=.c testfile
  33.     @smake m=.lisp testfile
  34.  
  35. #
  36. # Note: GoldED has to save test_xxx_correct.c as well (TAB saving en/disabled)...
  37. #
  38. testfile:
  39.     @echo "Starting GoldED and indenting test text for mode "$(m)"..."
  40.     @golded:ed
  41.     @waitforport GOLDED.1
  42.     @rx "mode='$(m)'; address GOLDED.1; 'OPEN SMART NEW 'pragma(d)'/test_input'mode; \
  43.          'SET TYPE 'mode; 'GOTO TOP'; \
  44.          'MARK HIDE'; 'MARK SET BEGIN'; 'GOTO BOTTOM'; 'MARK SET END'; \
  45.          'SMARTINDENT BLOCK'; 'SAVE ALL NAME t:test1'; 'SMARTINDENT BLOCK'; \
  46.          'SAVE ALL NAME t:test2'; 'SMARTINDENT BLOCK'; 'SAVE ALL NAME t:test3'; \
  47.          'OPEN SMART NEW 'pragma(d)'/test_correct'mode; 'SAVE ALL NAME t:correct'; \
  48.          'QUIT'; 'QUIT'"
  49.     @echo ""
  50.     @echo "Diffs between done and intented indention:"
  51.     @echo ------------------------------------------
  52.     -@diff -ct t:test1 t:correct
  53.     @echo ------------------------------------------
  54.     @echo ""
  55.     @echo "Diffs between first and second indention try:"
  56.     @echo ------------------------------------------
  57.     -@diff -ct t:test1 t:test2
  58.     @echo ------------------------------------------
  59.     @echo ""
  60.     @echo "Diffs between second and third indention try:"
  61.     @echo ------------------------------------------
  62.     -@diff -ct t:test2 t:test3
  63.     @echo ------------------------------------------
  64.     @echo ""
  65.     @echo "Solved bugs, that are still marked in the test text:"
  66.     @search >t:test.st from t:test3 search "!!!BUG!!!"
  67.     @search >t:test.sc from t:correct search "!!!BUG!!!"
  68.     -@diff "--old-line-format=" "--new-line-format=" "--unchanged-line-format=%L" t:test.st t:test.sc
  69.     @delete quiet t:test1 t:test2 t:test3 t:correct t:test.st t:test.sc
  70.  
  71.